package com.funtl.itoken.common.service;

import com.funtl.itoken.common.domain.BaseDomain;
import com.github.pagehelper.PageInfo;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

// @Service
@Transactional(readOnly = true)
public interface BaseService<T extends BaseDomain>  {
    @Transactional(readOnly = false)
    int insert(T t,String createBy);

    @Transactional(readOnly = false)
    int delete(T t);

    @Transactional(readOnly = false)
    int update(T t,String updateBy);

    T selectOne(T t);

    PageInfo<T> selectPage(int pageNum,int pageSize,T t);

    int selectCount(T t);
}
